<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@include file="../../mytags.jsp" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport"
          content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
    <title>我的设备</title>
    <script type="text/javascript" charset="utf-8">
        mui.init();
    </script>
</head>
<body>
<div class="fp_t">序列号：${equipment.sn }</div>
<div class="eq1">
    <div class="inrr inrr1">
        <h4><span>机型</span>${equipment.type.typeDesc }&nbsp;</h4>
        <h4><span>保修截止日期</span>${repairEndDate}&nbsp;</h4>
        <h4><span>上一次巡检日期</span>
            <c:if test="${empty lastEvaluateDate}">
                无
            </c:if>
            ${lastEvaluateDate }&nbsp;</h4>
        <h4><span>上一次巡检评分</span>
            <c:if test="${empty lastEvaluate}">
                无
            </c:if>
            ${lastEvaluate }&nbsp;</h4>
        <h4 style="color: #0eb972;"><span>是否有本年度巡检计划</span>
            <c:choose>
                <c:when test="${equipment.isHadInspection eq '1' }">是</c:when>
                <c:otherwise>否</c:otherwise>
            </c:choose>
            &nbsp;
        </h4>
    </div>
</div>
<div class="tix mui-clearfix">
    <img src="${webRoot }images/jg.png">
    <c:if test="${ceil >= 0 }">
        本设备距离出保日期还有
        <c:choose>
            <c:when test="${empty ceil }">0</c:when>
            <c:otherwise>${ceil }</c:otherwise>
        </c:choose>
        天
    </c:if>
    <c:if test="${ceil < 0 }">
        本设备已出保修期
    </c:if>
</div>
<c:if test="${equipment.isServicing eq '1'}">
    <div class="mui-content-padded" style="margin-top: 10px;">
        <a class="mui-btn mui-btn-block mui-btn-primary ljxb" href="#" onclick="goRepair('${equipment.sn }')">立即续保</a>
    </div>
</c:if>
<div class="mui-content-padded" style="margin-top: 10px;">
    <a class="mui-btn mui-btn-block mui-btn-primary" href="loginWxController.do?loginRedirect&type=1">查看增值产品</a>
</div>
</body>
<script type="text/javascript">
    function goRepair(sn) {
    	window.location.href = "wxMenuController.do?sbwbOrdNew&sn="+sn;
<%--        mui.alert("请拨打中影巴可24小时服务热线<a href='tel:400-88-22726' style='color:blue'>400-88-22726</a>咨询维保事宜");--%>
    }
</script>
</html>